#ifndef _SWITCH_H_
#define _SWITCH_H_

#include <sys/queue.h>
#include <rte_common.h>
#include <stdio.h>

/* State of virtio device. */
enum device_state {
	DEVICE_READY = 0,
	DEVICE_CLOSING = 1,
};


/* Device information */
struct dev_info {
	int virtual;    /* physical port (0) / virtual port (1) */
	int id;         /* portid / vid */
	volatile enum device_state state;

	TAILQ_ENTRY(dev_info) dev_entry;
} __rte_cache_aligned;

TAILQ_HEAD(dev_info_tailq, dev_info);

#endif